A second operation started on this context before a previous operation completed

2021-03-28_11-26-57.jpg

 

AddDbContext에 ServiceLifetime.Transient 옵션을 추가하면 가볍게 해결됩니다.

services.AddDbContext<ApplicationDbContext>(
    options => options.UseSqlServer(Configuration.GetConnectionString("DefaultConnection")
    , options => options.EnableRetryOnFailure()), ServiceLifetime.Transient);

 

 

Comments


Comments are closed